<%-- 
    Document   : applyonline
    Created on : Apr 10, 2011, 2:49:57 PM
    Author     : Duc Quyen
--%>

<%@page import="Model.JobSeeker"%>
<%@page import="Model.Job"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>Tìm Việc</title>

        <link href="style.css" rel="stylesheet" type="text/css" />
        <script type="text/javascript" src="resource/stmenu.js"></script>

        <script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>


        <script src="libjs/jquery-1.5.1.min.js"></script>

        <script type="text/javascript">
            function getStats(fName){
                fullName = fName;
                document.forms.aplly.dispName.value = fullName;
            }
        </script>
    </head>

    <body>
        <%        Job job = new Job();
                    int jobID = Integer.parseInt(request.getParameter("jobID"));
                    Job j = job.getJobByID(jobID);
                    JobSeeker jobSeeker = (JobSeeker) session.getAttribute("jobseeker");
        %>
        <div id="frame">
            <div id="page">
                <div id="header">
                    <script type="text/javascript">
                        AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','950','height','150','src','flash/header','quality','high','pluginspage','http://www.adobe.com/shockwave/download/\n\
                    download.cgi?P1_Prod_Version=ShockwaveFlash','movie','flash/header' ); //end AC code
                    </script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="950" height="150">
                            <param name="movie" value="flash/header.swf" />
                            <param name="quality" value="high" />
                            <embed src="flash/header.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="950" height="150"></embed>
                        </object>
                    </noscript></div>
                <div id="menu">
                    <a href="http://www.dhtml-menu-builder.com"  style="display:none;visibility:hidden;">Javascript DHTML Drop Down Menu Powered by dhtml-menu-builder.com</a>
                    <script type="text/javascript" src="resource/navigation.js"></script>
                </div>

                <div id="headerbanner">
                    <div class="bannerflash">
                        <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="340" height="150">
                            <param name="movie" value="flashbanner.swf" />
                            <param name="quality" value="high" />
                            <param name="allowFullScreen" value="false" />
                            <param name="allowScriptAccess" value="always" />
                            <param name="wmode" value="transparent" />
                            <embed src="flashbanner.swf"
                                   quality="high"
                                   type="application/x-shockwave-flash"
                                   wmode="transparent"
                                   width="340"
                                   height="150"
                                   allowfullscreen="false"
                                   pluginspage="http://www.macromedia.com/go/getflashplayer"
                                   allowscriptaccess="always" />
                        </object>
                    </div>
                    <div class="introduce">
                        <ul style="margin-top: 5px; margin-bottom: 5px;">
                            <li><span style="font-weight: bold; color: rgb(83, 112, 128);">Tìm Việc làm Cấp trung</span>: Tuyển Các cấp quản lý trung gian.</li>
                            <li><span style="font-weight: bold; color: rgb(83, 112, 128);">Tìm Việc làm Cấp sơ</span>: Sinh viên mới ra trường, kinh nghiệm làm việc dưới 3 năm.</li>
                            <li><span style="font-weight: bold; color: rgb(83, 112, 128);">Tìm Việc làm bán thời gian</span>: Tìm Việc làm thêm, việc làm sinh viên...</li>

                        </ul>
                        <span style="color: rgb(0, 102, 255); font-weight: bold;padding-left:100px;">Nhanh Chóng-Hiệu quả-Tiết kiệm</span>

                    </div>

                </div>
                <div id="infoemp" >
                    <div id="listjob">
                        <div class="grid">
                            <div class="box_header">
                                <h4 class="titlecenter">NỘP DƠN ỨNG TUYỂN</h4>
                            </div >
                            <div class="box_center">
                                <form name="aplly" action="SendMailToEmployer" method="post" ENCTYPE="multipart/form-data">
                                    <table cellpadding="3" class="loginform" id="apllyjob">
                                        <tbody><tr>
                                                <td width="132" valign="top" nowrap="nowrap" class="key">Chức danh/Vị trí:</td>
                                                <td width="658">
                                                    <strong><span class="impression"><%=j.getTitle()%></span></strong>
                                                </td>
                                            </tr>
                                            <tr>
                                                <td nowrap="nowrap" valign="top" class="key">Tên người ứng tuyển</td>
                                                <td>

                                                    <label>
                                                        <%=jobSeeker.getName()%>
                                                        <input type="hidden" name="jsname" value="<%=jobSeeker.getName()%>"/>
                                                        <input type="hidden" name="jobID" value="<%=jobID%>"/>
                                                    </label></td>
                                            </tr>
                                            <tr>
                                                <td nowrap="nowrap" valign="top" class="key">Tên người liên hệ:</td>
                                                <td>
                                                    <%=j.getContactPerson()%>
                                                </td>
                                            </tr>
                                            <tr>
                                                <td nowrap="nowrap" valign="top" class="key">Tiêu đề hồ sơ</td>
                                                <td><input name="titleapply" type="text" />						</td>
                                            </tr>

                                            <tr>
                                                <td nowrap="nowrap" valign="top" class="key">Email</td>
                                                <td>
                                                    <%=jobSeeker.getEmail()%>
                                                    <input type="hidden" name="mailjs" value="<%=jobSeeker.getEmail()%>"/>
                                                    <input type="hidden" name="mailemp" value="<%=j.getEmailForApply()%>"/>
                                                </td>
                                            </tr>
                                            <tr>
                                                <td nowrap="nowrap" valign="top" class="key">Thư giới thiệu</td>
                                                <td><label>
                                                        <textarea name="letter" id="letter" cols="45" rows="10"></textarea><br />

                                                    </label></td>
                                            </tr>
                                            <tr>
                                                <td nowrap="nowrap" valign="top" class="key">Hồ sơ đính kèm</td>
                                                <td>
                                                    <input type="file" name="document" value="" onchange="getStats(this.value)"/>
                                                    <input type="hidden" name="dispName" id="image">
                                                </td>
                                            </tr>
                                        </tbody></table>
                                    <div align="center" ><%String result = (String) request.getAttribute("result");
                                                if (result != null) {
                                                    out.print(result);
                                                }
                                        %></div>
                                    <div align="center" ><input name="send" type="submit" value="Ứng tuyển" /></div>
                                </form>

                            </div>

                        </div>
                    </div>


                </div>








            </div>

            <div id="footer">
                <div class="blank"></div>
                <div id="info-footer"><strong>&copy;Lê Đức Quyền-Nguyễn Xuân Tuấn</strong></div>
            </div>
        </div>
        <!--            end page -->

        <!--        end frame -->
    </body>
</html>
